package com.lmx.commen.model.entity;

import com.baomidou.mybatisplus.annotation.*;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * 接口信息表
 *
 * @TableName interfance_info
 */
@TableName(value = "interfance_info")
@Data
public class InterfanceInfo implements Serializable {
    /**
     * id
     */
    @TableId(type = IdType.AUTO)
    private Long id;

    /**
     * 接口名称
     */
    private String name;

    /**
     * 接口描述
     */
    private String decprition;
    /**
     *
     * 地址
    * */
    private String host;

    /**
     * 地址
     */
    private String url;

    /**
     * 请求方式
     */
    private String method;

    /**
     * 创建用户
     */
    private Long userid;

    /**
     * 接口状态0-关闭，1--打开
     */
    private Integer status;

    /**
     * 请求头
     */
    private String requestheader;

    /**
     * 响应头
     */
    private String reposeheader;



    /**
     * 接口参数
     */

    private String parameters;
    /**
     * 创建时间
     */
    private Date createtime;

    /**
     * 更新时间
     */
    private Date updatetime;

    /**
     * 是否删除
     */
    @TableLogic
    private Integer isdelete;

    @TableField(exist = false)
    private static final long serialVersionUID = 156161654156L;

    /**
     * id
     */
    public Long getId() {
        return id;
    }

    /**
     * id
     */
    public void setId(Long id) {
        this.id = id;
    }

    /**
     * 接口名称
     */
    public String getName() {
        return name;
    }

    /**
     * 接口名称
     */
    public void setName(String name) {
        this.name = name;
    }

    /**
     * 接口描述
     */
    public String getDecprition() {
        return decprition;
    }

    /**
     * 接口描述
     */
    public void setDecprition(String decprition) {
        this.decprition = decprition;
    }

    /**
     * 地址
     */
    public String getUrl() {
        return url;
    }

    /**
     * 地址
     */
    public void setUrl(String url) {
        this.url = url;
    }

    /**
     * 请求方式
     */
    public String getMethod() {
        return method;
    }

    /**
     * 请求方式
     */
    public void setMethod(String method) {
        this.method = method;
    }

    /**
     * 创建用户
     */
    public Long getUserid() {
        return userid;
    }

    /**
     * 创建用户
     */
    public void setUserid(Long userid) {
        this.userid = userid;
    }

    /**
     * 接口状态0-关闭，1--打开
     */
    public Integer getStatus() {
        return status;
    }

    /**
     * 接口状态0-关闭，1--打开
     */
    public void setStatus(Integer status) {
        this.status = status;
    }

    /**
     * 请求头
     */
    public String getRequestheader() {
        return requestheader;
    }


    public String getParameters() {
        return parameters;
    }

    public void setParameters(String parameters) {
        this.parameters = parameters;
    }
    /**
     * 请求头
     */
    public void setRequestheader(String requestheader) {
        this.requestheader = requestheader;
    }

    /**
     * 响应头
     */
    public String getReposeheader() {
        return reposeheader;
    }

    /**
     * 响应头
     */
    public void setReposeheader(String reposeheader) {
        this.reposeheader = reposeheader;
    }

    /**
     * 创建时间
     */
    public Date getCreatetime() {
        return createtime;
    }

    /**
     * 创建时间
     */
    public void setCreatetime(Date createtime) {
        this.createtime = createtime;
    }

    /**
     * 更新时间
     */
    public Date getUpdatetime() {
        return updatetime;
    }

    /**
     * 更新时间
     */
    public void setUpdatetime(Date updatetime) {
        this.updatetime = updatetime;
    }

    /**
     * 是否删除
     */
    public Integer getIsdelete() {
        return isdelete;
    }

    /**
     * 是否删除
     */
    public void setIsdelete(Integer isdelete) {
        this.isdelete = isdelete;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        InterfanceInfo other = (InterfanceInfo) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
                && (this.getName() == null ? other.getName() == null : this.getName().equals(other.getName()))
                && (this.getDecprition() == null ? other.getDecprition() == null : this.getDecprition().equals(other.getDecprition()))
                && (this.getUrl() == null ? other.getUrl() == null : this.getUrl().equals(other.getUrl()))
                && (this.getMethod() == null ? other.getMethod() == null : this.getMethod().equals(other.getMethod()))
                && (this.getUserid() == null ? other.getUserid() == null : this.getUserid().equals(other.getUserid()))
                && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
                && (this.getRequestheader() == null ? other.getRequestheader() == null : this.getRequestheader().equals(other.getRequestheader()))
                && (this.getReposeheader() == null ? other.getReposeheader() == null : this.getReposeheader().equals(other.getReposeheader()))
                && (this.getCreatetime() == null ? other.getCreatetime() == null : this.getCreatetime().equals(other.getCreatetime()))
                && (this.getUpdatetime() == null ? other.getUpdatetime() == null : this.getUpdatetime().equals(other.getUpdatetime()))
                && (this.getIsdelete() == null ? other.getIsdelete() == null : this.getIsdelete().equals(other.getIsdelete()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getName() == null) ? 0 : getName().hashCode());
        result = prime * result + ((getDecprition() == null) ? 0 : getDecprition().hashCode());
        result = prime * result + ((getUrl() == null) ? 0 : getUrl().hashCode());
        result = prime * result + ((getMethod() == null) ? 0 : getMethod().hashCode());
        result = prime * result + ((getUserid() == null) ? 0 : getUserid().hashCode());
        result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode());
        result = prime * result + ((getRequestheader() == null) ? 0 : getRequestheader().hashCode());
        result = prime * result + ((getReposeheader() == null) ? 0 : getReposeheader().hashCode());
        result = prime * result + ((getCreatetime() == null) ? 0 : getCreatetime().hashCode());
        result = prime * result + ((getUpdatetime() == null) ? 0 : getUpdatetime().hashCode());
        result = prime * result + ((getIsdelete() == null) ? 0 : getIsdelete().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", name=").append(name);
        sb.append(", decprition=").append(decprition);
        sb.append(", url=").append(url);
        sb.append(", method=").append(method);
        sb.append(", userid=").append(userid);
        sb.append(", status=").append(status);
        sb.append(", requestheader=").append(requestheader);
        sb.append(", reposeheader=").append(reposeheader);
        sb.append(", createtime=").append(createtime);
        sb.append(", updatetime=").append(updatetime);
        sb.append(", isdelete=").append(isdelete);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}